from typing import List


class Solution:
    def checkStraightLine(self, coordinates: List[List[int]]) -> bool:
        k = False
        for i in range(0, len(coordinates) - 1):
            x1, y1 = coordinates[i]
            x2, y2 = coordinates[(i+1)]
            k2 = None if x2 == x1 else (y2 - y1) / (x2 - x1)
            if k is False:
                k = k2
            if k != k2:
                return False
        return True